load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")

go_library(
    name = "go_default_library",
    srcs = [
        "context.go",
        "controller.go",
        "dispatcher.go",
        "env.go",
        "handler.go",
        "handlerTable.go",
        "init.go",
        "logger.go",
        "monitor.go",
        "resolver.go",
        "resourceType.go",
    ],
    visibility = ["//visibility:public"],
    deps = [
        "//mixer/pkg/adapter:go_default_library",
        "//mixer/pkg/aspect:go_default_library",
        "//mixer/pkg/attribute:go_default_library",
        "//mixer/pkg/config/proto:go_default_library",
        "//mixer/pkg/config/store:go_default_library",
        "//mixer/pkg/expr:go_default_library",
        "//mixer/pkg/pool:go_default_library",
        "//mixer/pkg/status:go_default_library",
        "//mixer/pkg/template:go_default_library",
        "//pkg/log:go_default_library",
        "@com_github_gogo_protobuf//proto:go_default_library",
        "@com_github_hashicorp_go_multierror//:go_default_library",
        "@com_github_opentracing_opentracing_go//:go_default_library",
        "@com_github_opentracing_opentracing_go//log:go_default_library",
        "@com_github_prometheus_client_golang//prometheus:go_default_library",
        "@io_istio_api//mixer/v1:go_default_library",
        "@io_istio_api//mixer/v1/config/descriptor:go_default_library",
        "@io_istio_api//mixer/v1/template:go_default_library",
        "@io_istio_gogo_genproto//googleapis/google/rpc:go_default_library",
        "@org_uber_go_zap//:go_default_library",
        "@org_uber_go_zap//zapcore:go_default_library",
    ],
)

go_test(
    name = "go_default_test",
    srcs = [
        "context_test.go",
        "controller_test.go",
        "dispatcher_test.go",
        "env_test.go",
        "handler_test.go",
        "resolver_test.go",
        "resourceType_test.go",
    ],
    library = ":go_default_library",
    deps = [
        "@com_github_golang_protobuf//ptypes/empty:go_default_library",
        "@com_github_golang_protobuf//ptypes/wrappers:go_default_library",
    ],
)
